<div style="position:absolute;" class="popup_edit">
    <% if @user && !@user.valid? %>
    <div id="login_error">
        <%= error_messages(@user) %>
        <br/>
    </div>
    <% end %>
	
    <% form_for :user, :url => users_path do |f| -%>
	<table>
		<tr>
			<td style="text-align: right">
				<label for="login">用户名:&nbsp;&nbsp;</label>
			</td>
			<td>
				<%= f.text_field :login, :class=>"input" %>
			</td>
		</tr>
		<tr>
			<td style="text-align: right">
				<label for="email">Email:&nbsp;&nbsp;</label>
			</td>
			<td>
				<%= f.text_field :email, :class=>"input" %>
			</td>
		</tr>
		<tr>
			<td style="text-align: right">
				<label for="password">密码:&nbsp;&nbsp;</label>
			</td>
			<td>
				<%= f.password_field :password, :class=>"input" %>
			</td>
		</tr>
		<tr>
			<td style="text-align: right">
				<label for="password_confirmation">确认密码:&nbsp;&nbsp;</label>
			</td>
			<td>
				<%= f.password_field :password_confirmation, :class=>"input" %>
			</td>
		</tr>
		<tr>
    		<td>
			</td>
			<td>
				<input type="submit" value="注册" />&nbsp;&nbsp;&nbsp;<input id="close_signup" type="button" value="取消" />
			</td>
    	</tr>
	</table>
    <% end -%>
</div>
<style>
    .popup_edit {
        color: #000;
        font: 12px / 1.6em Helvetica, Arial, sans-serif;
        text-align: left;
        line-height: 1.4em;
        padding: 30px 50px;
        overflow: hidden;
        background-repeat: repeat-x;
        background-position: 0 1px;
    }
	
	.popup_edit input, .popup_edit textarea {
        border-width: 1px;
        background: #FFF;
        border-color: #DDD;
    }
</style>
<script>
	$("#close_signup").click(tb_remove);
</script>